<template>
    <el-pagination v-model:current-page="currentPage" v-model:page-size="pageSize" :page-sizes="[10, 20, 30, 40]"
        layout="total, sizes, prev, pager, next, jumper" :total="100" @size-change="handleSizeChange"
        @current-change="handleCurrentChange" />
</template>

<script setup>
import { ref } from 'vue'


// 分页
let currentPage = ref(1)
let pageSize = ref(10)
let total = ref(null)
const handleSizeChange = (val) => {
    console.log(`${val} items per page`)
}
const handleCurrentChange = (val) => {
    console.log(`current page: ${val}`)
}
</script>

<style></style>